body {
    margin: 0;
    padding: 0;
    background-color: #000;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    overflow: hidden;
    font-family: 'Courier New', Courier, monospace;
    color: white;
}

#game-container {
    position: relative;
    border: 2px solid #fff;
    box-shadow: 0 0 20px #fff;
}

canvas {
    display: block;
}

#score-container {
    position: absolute;
    top: 10px;
    left: 10px;
    color: #fff;
    font-size: 24px;
    z-index: 10;
}

#start-screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.8);
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    z-index: 20;
}

#start-screen h1 {
    font-size: 48px;
    margin-bottom: 20px;
}

#start-screen p {
    font-size: 24px;
    margin-bottom: 40px;
}

#startButton {
    font-size: 24px;
    padding: 10px 20px;
    background-color: #333;
    color: white;
    border: 2px solid white;
    cursor: pointer;
    font-family: 'Courier New', Courier, monospace;
}

#startButton:hover {
    background-color: #555;
}

#main-menu, #settings-screen, #skins-screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.8);
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    z-index: 20;
}

#skins-screen {
    justify-content: flex-start;
    padding-top: 30px;
    box-sizing: border-box;
}

#main-menu h1 {
    font-size: 64px;
    margin-bottom: 20px;
    color: #0ff;
    text-shadow: 0 0 15px #0ff;
}

#main-menu p {
    font-size: 20px;
    color: #ccc;
    max-width: 90%;
    line-height: 1.4;
    margin-bottom: 20px;
}

#final-score-text {
    font-size: 28px;
    color: #ff0;
    margin-top: 20px;
    margin-bottom: 20px;
}

.menu-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 30px;
}

#main-menu button, #settings-screen button, #skins-screen button, #shop-screen button, #game-over-screen button {
    font-size: 24px;
    padding: 10px 30px;
    background-color: transparent;
    color: white;
    border: 2px solid white;
    cursor: pointer;
    font-family: 'Courier New', Courier, monospace;
    transition: background-color 0.2s, color 0.2s, box-shadow 0.2s;
    min-width: 250px;
}

#main-menu button:hover, #settings-screen button:hover, #skins-screen button:hover, #shop-screen button:hover, #game-over-screen button:hover {
    background-color: white;
    color: black;
    box-shadow: 0 0 15px #fff;
}

#settings-screen h2, #skins-screen h2, #shop-screen h2 {
    font-size: 48px;
    margin-bottom: 30px;
    color: #0ff;
    text-shadow: 0 0 15px #0ff;
}

.setting-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 80%;
    max-width: 400px;
    margin-bottom: 20px;
    font-size: 20px;
}

.controls-heading {
    justify-content: center;
    margin-bottom: 10px;
    margin-top: 20px;
    font-size: 24px;
    color: #0ff;
}

.control-button {
    font-size: 18px !important;
    padding: 5px 15px !important;
    min-width: 150px !important;
}

.control-button:focus {
    border-color: #ff0;
    color: #ff0;
}

#volume-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 200px;
    height: 8px;
    background: #555;
    outline: none;
    opacity: 0.7;
    transition: opacity .2s;
    border-radius: 5px;
    border: 1px solid #fff;
}

#volume-slider:hover {
    opacity: 1;
}

#volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  background: #0ff;
  cursor: pointer;
  border-radius: 50%;
  border: 2px solid white;
}

#volume-slider::-moz-range-thumb {
  width: 20px;
  height: 20px;
  background: #0ff;
  cursor: pointer;
  border-radius: 50%;
   border: 2px solid white;
}

#back-button {
    margin-top: 30px;
}

#back-button-skins {
    position: absolute;
    top: 20px;
    left: 20px;
    font-size: 18px !important;
    padding: 10px 20px !important;
    min-width: unset !important;
}

#highscore-container {
    margin-bottom: 20px;
    width: 80%;
    max-width: 300px;
}

#highscore-container h2 {
    font-size: 28px;
    color: #0ff;
    text-shadow: 0 0 10px #0ff;
    margin-bottom: 10px;
}

#highscore-list {
    list-style-type: decimal;
    padding-left: 40px;
    text-align: left;
    font-size: 20px;
    color: #eee;
}

#highscore-list li {
    margin-bottom: 5px;
}

#coins-earned {
    color: #ffd700;
    font-size: 24px;
    margin-bottom: 20px;
    text-shadow: 0 0 5px #ffd700;
}

#skin-selection-container {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;
    max-width: 540px;
    padding: 10px;
}

.skin-preview {
    box-sizing: border-box;
    width: 150px;
    height: auto;
    min-height: 120px;
    padding: 10px;
    border: 4px solid #fff;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    background-color: rgba(255, 255, 255, 0.1);
    transition: transform 0.2s, border-color 0.2s;
    position: relative;
}

.skin-preview:hover {
    transform: scale(1.1);
    border-color: #0ff;
}

.skin-preview.selected {
    border-color: #ff0;
    box-shadow: 0 0 15px #ff0;
    transform: scale(1.1);
}

.skin-preview img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    margin-bottom: 10px;
}

.skin-info {
    text-align: center;
}

.skin-info p {
    margin: 5px 0;
    font-size: 16px;
}

.skin-info button {
    font-size: 16px !important;
    padding: 5px 10px !important;
    min-width: unset !important;
    margin-top: 5px;
}

.skin-info button:disabled {
    background-color: #333 !important;
    color: #777 !important;
    border-color: #555 !important;
    cursor: not-allowed !important;
    box-shadow: none !important;
}

#game-over-screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.8);
    color: white;
    display: none; /* Initially hidden */
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    z-index: 20;
}

#game-over-screen h1 {
    font-size: 64px;
    margin-bottom: 20px;
    color: #ff4444;
    text-shadow: 0 0 15px #ff4444;
}

#game-over-screen p {
    font-size: 28px;
    color: #ff0;
    margin-bottom: 40px;
}

#game-over-screen button {
    font-size: 24px;
    padding: 10px 30px;
    background-color: transparent;
    color: white;
    border: 2px solid white;
    cursor: pointer;
    font-family: 'Courier New', Courier, monospace;
    transition: background-color 0.2s, color 0.2s, box-shadow 0.2s;
    min-width: 250px;
    margin-bottom: 15px;
}

#shop-screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.8);
    color: white;
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    z-index: 20;
}

.shop-items-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 30px;
    width: 80%;
    max-width: 500px;
}

.shop-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: rgba(255,255,255,0.1);
    padding: 15px;
    border: 2px solid #fff;
    font-size: 20px;
}

.shop-item button {
    font-size: 18px !important;
    padding: 8px 16px !important;
    min-width: unset !important;
}

.shop-item button:disabled {
    background-color: #333 !important;
    color: #777 !important;
    border-color: #555 !important;
    cursor: not-allowed !important;
    box-shadow: none !important;
}

#shop-screen > button {
    margin-top: 10px;
}